package com.hl.service.serviceImpl;

import com.hl.domain.Hearttest;
import com.hl.mapper.HearttestMapper;
import com.hl.service.HeartTestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class HeartTestServiceImpl implements HeartTestService {
    @Autowired
    private HearttestMapper hearttestMapper;
    @Override
    public List<Hearttest> selectAll() {
        return hearttestMapper.selectALL();
    }

    @Override
    public List<Hearttest> selectLike(String title) {
        return hearttestMapper.selectLike(title);
    }

    @Override
    public int insert(Hearttest hearttest) {
        return hearttestMapper.insert(hearttest);
    }

    @Override
    public int update(Hearttest hearttest) {
        return hearttestMapper.updateByPrimaryKey(hearttest);
    }

    @Override
    public int delete(Long id) {
        return hearttestMapper.deleteByPrimaryKey(id);
    }


}
